<template>
  <div class="flow-row-container">
    <FlowApproverNode v-if="node && (node.type === 1 || node.type === 6)" :node="node" :readable="readable"/>
    <FlowCcNode v-if="node && node.type === 2" :node="node" :readable="readable"/>
    <FlowRootNode v-if="node && node.type === 0" :node="node" :readable="readable"/>
    <FlowConditionNode v-if="node && node.type === 4" :node="node" :readable="readable"/>
    <FlowConcurrentNode v-if="node && node.type === 9" :node="node" :readable="readable"/>
    <FlowSuggestNode v-if="node && node.type === 7" :node="node" :readable="readable"/>
    <FlowPolymerizeNode v-if="node && node.type === 11" :node="node" :readable="readable"/>
    <FlowEventNode v-if="node && node.type === 5" :node="node" :readable="readable"/>
    <FlowNoticeNode v-if="node && node.type === 20" :node="node" :readable="readable"/>
    <FlowSubNode v-if="node && node.type === 21" :node="node" :readable="readable"/>
    <FlowNode v-if="node && node.childNode && node.childNode.hasOwnProperty('name')" :node="node.childNode"
              :readable="readable"/>
  </div>
</template>
<script setup name="FlowNode">
// import { flowMixin } from '../mixins/flowMixin';
import FlowNode from './FlowNode.vue';
import FlowCcNode from './FlowCcNode.vue';
import FlowRootNode from './FlowRootNode.vue';
import FlowApproverNode from './FlowApproverNode.vue';
import FlowConditionNode from './FlowConditionNode.vue'
import FlowConcurrentNode from './FlowConcurrentNode.vue';
import FlowSuggestNode from './FlowSuggestNode.vue';
import FlowPolymerizeNode from './FlowPolymerizeNode.vue';
import FlowEventNode from './FlowEventNode.vue';
import FlowNoticeNode from './FlowNoticeNode.vue';
import FlowSubNode from './FlowSubNode.vue';
import {reactive, ref, createApp,  defineProps} from "vue";
/* 组件局部注册 */
const app = createApp({});

//接收父组件传过来的值

defineProps({
  node: {
    type: Object,
    default: function () {
      return {};
    },
  },
  readable: {
    type: Boolean,
    default: false,
  },
})
</script>
